Optimal. Leaf size=261 \[ -\frac {(i A+B) (a+i a \tan (e+f x))^{7/2}}{15 f (c-i c \tan (e+f x))^{15/2}}-\frac {(4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{195 c f (c-i c \tan (e+f x))^{13/2}}-\frac {(4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{715 c^2 f (c-i c \tan (e+f x))^{11/2}}-\frac {2 (4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{6435 c^3 f (c-i c \tan (e+f x))^{9/2}}-\frac {2 (4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{45045 c^4 f (c-i c \tan (e+f x))^{7/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.21, antiderivative size = 261, normalized size of antiderivative = 1.00, number of steps
used = 6, number of rules used = 4, integrand size = 45, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.089, Rules used = {3669, 79, 47,
37} \begin {gather*} -\frac {2 (-11 B+4 i A) (a+i a \tan (e+f x))^{7/2}}{45045 c^4 f (c-i c \tan (e+f x))^{7/2}}-\frac {2 (-11 B+4 i A) (a+i a \tan (e+f x))^{7/2}}{6435 c^3 f (c-i c \tan (e+f x))^{9/2}}-\frac {(-11 B+4 i A) (a+i a \tan (e+f x))^{7/2}}{715 c^2 f (c-i c \tan (e+f x))^{11/2}}-\frac {(-11 B+4 i A) (a+i a \tan (e+f x))^{7/2}}{195 c f (c-i c \tan (e+f x))^{13/2}}-\frac {(B+i A) (a+i a \tan (e+f x))^{7/2}}{15 f (c-i c \tan (e+f x))^{15/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 37
Rule 47
Rule 79
Rule 3669
Rubi steps
\begin {align*} \int \frac {(a+i a \tan (e+f x))^{7/2} (A+B \tan (e+f x))}{(c-i c \tan (e+f x))^{15/2}} \, dx &=\frac {(a c) \text {Subst}\left (\int \frac {(a+i a x)^{5/2} (A+B x)}{(c-i c x)^{17/2}} \, dx,x,\tan (e+f x)\right )}{f}\\ &=-\frac {(i A+B) (a+i a \tan (e+f x))^{7/2}}{15 f (c-i c \tan (e+f x))^{15/2}}+\frac {(a (4 A+11 i B)) \text {Subst}\left (\int \frac {(a+i a x)^{5/2}}{(c-i c x)^{15/2}} \, dx,x,\tan (e+f x)\right )}{15 f}\\ &=-\frac {(i A+B) (a+i a \tan (e+f x))^{7/2}}{15 f (c-i c \tan (e+f x))^{15/2}}-\frac {(4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{195 c f (c-i c \tan (e+f x))^{13/2}}+\frac {(a (4 A+11 i B)) \text {Subst}\left (\int \frac {(a+i a x)^{5/2}}{(c-i c x)^{13/2}} \, dx,x,\tan (e+f x)\right )}{65 c f}\\ &=-\frac {(i A+B) (a+i a \tan (e+f x))^{7/2}}{15 f (c-i c \tan (e+f x))^{15/2}}-\frac {(4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{195 c f (c-i c \tan (e+f x))^{13/2}}-\frac {(4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{715 c^2 f (c-i c \tan (e+f x))^{11/2}}+\frac {(2 a (4 A+11 i B)) \text {Subst}\left (\int \frac {(a+i a x)^{5/2}}{(c-i c x)^{11/2}} \, dx,x,\tan (e+f x)\right )}{715 c^2 f}\\ &=-\frac {(i A+B) (a+i a \tan (e+f x))^{7/2}}{15 f (c-i c \tan (e+f x))^{15/2}}-\frac {(4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{195 c f (c-i c \tan (e+f x))^{13/2}}-\frac {(4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{715 c^2 f (c-i c \tan (e+f x))^{11/2}}-\frac {2 (4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{6435 c^3 f (c-i c \tan (e+f x))^{9/2}}+\frac {(2 a (4 A+11 i B)) \text {Subst}\left (\int \frac {(a+i a x)^{5/2}}{(c-i c x)^{9/2}} \, dx,x,\tan (e+f x)\right )}{6435 c^3 f}\\ &=-\frac {(i A+B) (a+i a \tan (e+f x))^{7/2}}{15 f (c-i c \tan (e+f x))^{15/2}}-\frac {(4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{195 c f (c-i c \tan (e+f x))^{13/2}}-\frac {(4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{715 c^2 f (c-i c \tan (e+f x))^{11/2}}-\frac {2 (4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{6435 c^3 f (c-i c \tan (e+f x))^{9/2}}-\frac {2 (4 i A-11 B) (a+i a \tan (e+f x))^{7/2}}{45045 c^4 f (c-i c \tan (e+f x))^{7/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [B] Both result and optimal contain complex but leaf count is larger than twice
the leaf count of optimal. \(577\) vs. \(2(261)=522\).
time = 16.81, size = 577, normalized size = 2.21 \begin {gather*} \frac {\cos ^4(e+f x) \left ((-i A+B) \cos (6 f x) \left (\frac {\cos (3 e)}{224 c^8}+\frac {i \sin (3 e)}{224 c^8}\right )+(-37 i A+23 B) \cos (8 f x) \left (\frac {\cos (5 e)}{2016 c^8}+\frac {i \sin (5 e)}{2016 c^8}\right )+(-49 i A+11 B) \cos (10 f x) \left (\frac {\cos (7 e)}{1584 c^8}+\frac {i \sin (7 e)}{1584 c^8}\right )+(61 A-11 i B) \cos (12 f x) \left (-\frac {i \cos (9 e)}{2288 c^8}+\frac {\sin (9 e)}{2288 c^8}\right )+(73 A-43 i B) \cos (14 f x) \left (-\frac {i \cos (11 e)}{6240 c^8}+\frac {\sin (11 e)}{6240 c^8}\right )+(A-i B) \cos (16 f x) \left (-\frac {i \cos (13 e)}{480 c^8}+\frac {\sin (13 e)}{480 c^8}\right )+(A+i B) \left (\frac {\cos (3 e)}{224 c^8}+\frac {i \sin (3 e)}{224 c^8}\right ) \sin (6 f x)+(37 A+23 i B) \left (\frac {\cos (5 e)}{2016 c^8}+\frac {i \sin (5 e)}{2016 c^8}\right ) \sin (8 f x)+(49 A+11 i B) \left (\frac {\cos (7 e)}{1584 c^8}+\frac {i \sin (7 e)}{1584 c^8}\right ) \sin (10 f x)+(61 A-11 i B) \left (\frac {\cos (9 e)}{2288 c^8}+\frac {i \sin (9 e)}{2288 c^8}\right ) \sin (12 f x)+(73 A-43 i B) \left (\frac {\cos (11 e)}{6240 c^8}+\frac {i \sin (11 e)}{6240 c^8}\right ) \sin (14 f x)+(A-i B) \left (\frac {\cos (13 e)}{480 c^8}+\frac {i \sin (13 e)}{480 c^8}\right ) \sin (16 f x)\right ) \sqrt {\sec (e+f x) (c \cos (e+f x)-i c \sin (e+f x))} (a+i a \tan (e+f x))^{7/2} (A+B \tan (e+f x))}{f (\cos (f x)+i \sin (f x))^3 (A \cos (e+f x)+B \sin (e+f x))} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.45, size = 206, normalized size = 0.79
method | result | size |
risch | \(-\frac {a^{3} \sqrt {\frac {a \,{\mathrm e}^{2 i \left (f x +e \right )}}{{\mathrm e}^{2 i \left (f x +e \right )}+1}}\, \left (3003 i A \,{\mathrm e}^{14 i \left (f x +e \right )}+3003 B \,{\mathrm e}^{14 i \left (f x +e \right )}+13860 i A \,{\mathrm e}^{12 i \left (f x +e \right )}+6930 B \,{\mathrm e}^{12 i \left (f x +e \right )}+24570 i A \,{\mathrm e}^{10 i \left (f x +e \right )}+20020 i A \,{\mathrm e}^{8 i \left (f x +e \right )}-10010 B \,{\mathrm e}^{8 i \left (f x +e \right )}+6435 i A \,{\mathrm e}^{6 i \left (f x +e \right )}-6435 B \,{\mathrm e}^{6 i \left (f x +e \right )}\right )}{720720 c^{7} \sqrt {\frac {c}{{\mathrm e}^{2 i \left (f x +e \right )}+1}}\, f}\) | \(169\) |
derivativedivides | \(-\frac {\sqrt {a \left (1+i \tan \left (f x +e \right )\right )}\, \sqrt {-c \left (i \tan \left (f x +e \right )-1\right )}\, a^{3} \left (1+\tan ^{2}\left (f x +e \right )\right ) \left (22 i B \left (\tan ^{6}\left (f x +e \right )\right )+72 i A \left (\tan ^{5}\left (f x +e \right )\right )+8 A \left (\tan ^{6}\left (f x +e \right )\right )-825 i B \left (\tan ^{4}\left (f x +e \right )\right )-198 B \left (\tan ^{5}\left (f x +e \right )\right )-780 i A \left (\tan ^{3}\left (f x +e \right )\right )-300 A \left (\tan ^{4}\left (f x +e \right )\right )-7260 i B \left (\tan ^{2}\left (f x +e \right )\right )+2145 B \left (\tan ^{3}\left (f x +e \right )\right )-6858 i A \tan \left (f x +e \right )+1455 A \left (\tan ^{2}\left (f x +e \right )\right )-407 i B -3663 B \tan \left (f x +e \right )-4243 A \right )}{45045 f \,c^{8} \left (i+\tan \left (f x +e \right )\right )^{9}}\) | \(206\) |
default | \(-\frac {\sqrt {a \left (1+i \tan \left (f x +e \right )\right )}\, \sqrt {-c \left (i \tan \left (f x +e \right )-1\right )}\, a^{3} \left (1+\tan ^{2}\left (f x +e \right )\right ) \left (22 i B \left (\tan ^{6}\left (f x +e \right )\right )+72 i A \left (\tan ^{5}\left (f x +e \right )\right )+8 A \left (\tan ^{6}\left (f x +e \right )\right )-825 i B \left (\tan ^{4}\left (f x +e \right )\right )-198 B \left (\tan ^{5}\left (f x +e \right )\right )-780 i A \left (\tan ^{3}\left (f x +e \right )\right )-300 A \left (\tan ^{4}\left (f x +e \right )\right )-7260 i B \left (\tan ^{2}\left (f x +e \right )\right )+2145 B \left (\tan ^{3}\left (f x +e \right )\right )-6858 i A \tan \left (f x +e \right )+1455 A \left (\tan ^{2}\left (f x +e \right )\right )-407 i B -3663 B \tan \left (f x +e \right )-4243 A \right )}{45045 f \,c^{8} \left (i+\tan \left (f x +e \right )\right )^{9}}\) | \(206\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.70, size = 352, normalized size = 1.35 \begin {gather*} \frac {{\left (3003 \, {\left (-i \, A - B\right )} a^{3} \cos \left (\frac {15}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right ) + 6930 \, {\left (-2 i \, A - B\right )} a^{3} \cos \left (\frac {13}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right ) - 24570 i \, A a^{3} \cos \left (\frac {11}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right ) + 10010 \, {\left (-2 i \, A + B\right )} a^{3} \cos \left (\frac {9}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right ) + 6435 \, {\left (-i \, A + B\right )} a^{3} \cos \left (\frac {7}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right ) + 3003 \, {\left (A - i \, B\right )} a^{3} \sin \left (\frac {15}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right ) + 6930 \, {\left (2 \, A - i \, B\right )} a^{3} \sin \left (\frac {13}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right ) + 24570 \, A a^{3} \sin \left (\frac {11}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right ) + 10010 \, {\left (2 \, A + i \, B\right )} a^{3} \sin \left (\frac {9}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right ) + 6435 \, {\left (A + i \, B\right )} a^{3} \sin \left (\frac {7}{2} \, \arctan \left (\sin \left (2 \, f x + 2 \, e\right ), \cos \left (2 \, f x + 2 \, e\right )\right )\right )\right )} \sqrt {a}}{720720 \, c^{\frac {15}{2}} f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 5.76, size = 175, normalized size = 0.67 \begin {gather*} -\frac {{\left (3003 \, {\left (i \, A + B\right )} a^{3} e^{\left (17 i \, f x + 17 i \, e\right )} + 231 \, {\left (73 i \, A + 43 \, B\right )} a^{3} e^{\left (15 i \, f x + 15 i \, e\right )} + 630 \, {\left (61 i \, A + 11 \, B\right )} a^{3} e^{\left (13 i \, f x + 13 i \, e\right )} + 910 \, {\left (49 i \, A - 11 \, B\right )} a^{3} e^{\left (11 i \, f x + 11 i \, e\right )} + 715 \, {\left (37 i \, A - 23 \, B\right )} a^{3} e^{\left (9 i \, f x + 9 i \, e\right )} + 6435 \, {\left (i \, A - B\right )} a^{3} e^{\left (7 i \, f x + 7 i \, e\right )}\right )} \sqrt {\frac {a}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}} \sqrt {\frac {c}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}}}{720720 \, c^{8} f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 13.48, size = 191, normalized size = 0.73 \begin {gather*} -\frac {\sqrt {a+\frac {a\,\sin \left (e+f\,x\right )\,1{}\mathrm {i}}{\cos \left (e+f\,x\right )}}\,\left (\frac {a^3\,{\mathrm {e}}^{e\,8{}\mathrm {i}+f\,x\,8{}\mathrm {i}}\,\left (2\,A+B\,1{}\mathrm {i}\right )\,1{}\mathrm {i}}{72\,c^7\,f}+\frac {a^3\,{\mathrm {e}}^{e\,12{}\mathrm {i}+f\,x\,12{}\mathrm {i}}\,\left (2\,A-B\,1{}\mathrm {i}\right )\,1{}\mathrm {i}}{104\,c^7\,f}+\frac {A\,a^3\,{\mathrm {e}}^{e\,10{}\mathrm {i}+f\,x\,10{}\mathrm {i}}\,3{}\mathrm {i}}{88\,c^7\,f}+\frac {a^3\,{\mathrm {e}}^{e\,6{}\mathrm {i}+f\,x\,6{}\mathrm {i}}\,\left (A+B\,1{}\mathrm {i}\right )\,1{}\mathrm {i}}{112\,c^7\,f}+\frac {a^3\,{\mathrm {e}}^{e\,14{}\mathrm {i}+f\,x\,14{}\mathrm {i}}\,\left (A-B\,1{}\mathrm {i}\right )\,1{}\mathrm {i}}{240\,c^7\,f}\right )}{\sqrt {c-\frac {c\,\sin \left (e+f\,x\right )\,1{}\mathrm {i}}{\cos \left (e+f\,x\right )}}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________